package com.design.pattern.behavioral.observer;

import java.util.Observable;

/**
 * description
 *
 * @author RenQiQiang 2019/03/28 9:40
 */
public class Course extends Observable {

    private String courseName;

    public Course(String courseName) {
        this.courseName = courseName;
    }

    public String getCourseName() {
        return courseName;
    }

    public void setCourseName(String courseName) {
        this.courseName = courseName;
    }

    public void produceQuestion(Course course, Question question){
        setChanged();
        notifyObservers(question);
    }
}
